﻿#region Header
// ------------------------ Licence / Copyright ------------------------
// 
// ScrumTable for Scrum Meeting Support
// Copyright © HSR - Hochschule für Technik Rapperswil
// All Rights Reserved
// 
// Author:
//  Michael Gfeller Silvan Gehrig Patrick Boos
// 
// ---------------------------------------------------------------------
#endregion

#region Usings

using System;
using ScrumTable.Common;
using ScrumTable.Common.Collections;
using ScrumTable.DL.Data.Generic.Properties;

#endregion

namespace ScrumTable.DL.Data.Generic.Cache
{
    /// <summary>
    /// Contains information about an cache element which should be merged
    /// into the existing hierarchy.
    /// </summary>
    /// <typeparam name="T">Specifies the type of the cache element inside the bucket.</typeparam>
    internal class CacheElementMergeInfo<T>
        where T : class, ICacheElement
    {
        #region Declarations
        //--------------------------------------------------------------------
        // Declarations
        //--------------------------------------------------------------------

        #endregion

        #region Properties
        //--------------------------------------------------------------------
        // Properties
        //--------------------------------------------------------------------

        internal CacheElementListEntryBucket<T> Bucket { get; private set; }

        internal ICacheSaveProgressFeedback SaveFeedback { get; private set; }

        #endregion

        #region Constructors / Destructor
        //--------------------------------------------------------------------
        // Constructors / Destructor
        //--------------------------------------------------------------------

        /// <summary>
        /// Initializes a new instance of the <see cref="CacheElementMergeInfo&lt;T&gt;"/> class.
        /// </summary>
        internal CacheElementMergeInfo(CacheElementListEntryBucket<T> bucket, ICacheSaveProgressFeedback saveFeedback)
        {
            PreCondition.AssertNotNull(bucket, "bucket");
            PreCondition.AssertNotNull(saveFeedback, "saveFeedback");

            Bucket = bucket;
            SaveFeedback = saveFeedback;
        }

        #endregion

        #region Methods
        //--------------------------------------------------------------------
        // Methods
        //--------------------------------------------------------------------

        #endregion

        #region Events
        //--------------------------------------------------------------------
        // Events
        //--------------------------------------------------------------------

        #endregion
    }
}